#include "OmniL.h"

OmniL::OmniL( float f[4],float a[4], float d[4], float s[4], bool on , int LightX):Light(a,d,s,on,LightX)
{
	for(int i=0; i<4;++i)
		location[i]=f[i];

	glLightfv(getLightX(), GL_AMBIENT, getAmbient());
	glLightfv(getLightX(), GL_DIFFUSE, getDiffuse());
	glLightfv(getLightX(), GL_SPECULAR, getSpecular());
}

void OmniL::act()
{
	glLightfv(getLightX(), GL_POSITION, location);
}
